<?php
/**
 * auth_register.inc
 * Template: User registration form.
 * @copyright	Copyright(c) 2002-2010 Bjorn Winberg
 * @author		Bjorn Winberg <cms@anomalye.net>
 * @license		http://www.gnu.org/licenses/gpl.html GNU General Public License version 2
 * @package		AnomalyWiki
 */
?>
<div class="helpBox">
	<?php echo $this->localString('RF_HELP');?>
</div>

<form class="simpleForm" id="auth_registerForm" action="<?php echo $this->generateUrl('auth', array('a' => 'register'));?>" method='post'>
	<fieldset>
	<legend><?php echo $this->localString('RF_REGISTER');?></legend>
	<?php
		if($this->isEmptyUserTable($aParams['db'])){
			echo '<div class="simpleRequired">';
			echo '<label for="install_password">' . $this->localString('RF_INSTALL_PASSWORD') . '</label>';
			echo '<input type="text" name="install_password" id="install_password" value="" maxlength="' . Auth::PARAM_MAX_PASSWORD . '" />';
			echo '</div>';
		}
	?>
	<div class="simpleRequired">
		<label for="name"><?php echo $this->localString('RF_NAME');?></label>
		<input type='text' name='name' id='name' value="" maxlength="<?php echo Auth::PARAM_MAX_NAME;?>" />
	</div>
	<div class="simpleRequired">
		<label for="password"><?php echo $this->localString('RF_PASSWORD');?></label>
		<input type='password' name='password' id='password' value="" maxlength="<?php echo Auth::PARAM_MAX_PASSWORD;?>" />
	</div>
	<div class="simpleRequired">
		<label for="confirmpass"><?php echo $this->localString('RF_CONFIRM_PASS');?></label>
		<input type='password' name='confirmpass' id='confirmpass' value="" maxlength="<?php echo Auth::PARAM_MAX_PASSWORD;?>" />
	</div>
	<input type='submit' name='submit' value="<?php echo $this->localString('RF_SUBMIT');?>" />
	</fieldset>
</form>

